<p><?php echo count($listEtudiant)?> étudiants trouvés:</p>
<table class="scrollTable liste">
<thead>
<tr><th></th><th>Nom</th><th>Prénom</th><th>Groupe TD</th><th>P</th><th>R</th><th>ABJ</th><th>AB</th></tr>
<thead>
<tbody>
<?php foreach ($listEtudiant as $key => $etudiant) {?>
<tr>
    <td><img class="editerEtu click_mouse" id="editerEtu_<?php echo $etudiant["NumUtilisateur"]?>" src="images/icon-editer.png" title="Modifier présences" alt="Modifier présences"/> </td>
    <td id="editerEtuN_<?php echo $etudiant["NumUtilisateur"]?>" > <?php echo $etudiant["NomUtilisateur"];?></td>
    <td id="editerEtuP_<?php echo $etudiant["NumUtilisateur"]?>" > <?php echo $etudiant["PrenomUtilisateur"];?></td>
    <td>
        <?php 
            $grp= $bda->getGroupeByEtuEP($etudiant["NumEtudiant"],isset($formFilter)?$formFilter->getNumEp():$numEP) ;
            echo ($grp?$grp["numgrp"]:""); 
        ?>
    </td>

    <?php 
    $presences=$bda->getPresences($etudiant["NumUtilisateur"],isset($formFilter)?$formFilter->getNumEp():$numEP, isset($formFilter)?$formFilter->getAnnee():$annee);
    
    ?>
    <td <?php echo (isset($presences["P"]) && $presences["P"]["nb"]>0)?"class='P_green'":""; ?>><?php echo isset($presences["P"])?$presences["P"]["nb"]:0;?></td>
    <td <?php echo (isset($presences["R"]) && $presences["R"]["nb"]>0)?"class='R_yellow'":"";?>><?php echo isset($presences["R"])?$presences["R"]["nb"]:0;?></td>
    <td <?php echo (isset($presences["ABJ"]) && $presences["ABJ"]["nb"]>0)?"class='ABJ_orange'":"";?>><?php echo isset($presences["ABJ"])?$presences["ABJ"]["nb"]:0;?></td>
    <td <?php echo (isset($presences["AB"]) && $presences["AB"]["nb"]>0)?"class='AB_red'":"";?>><?php echo isset($presences["AB"])?$presences["AB"]["nb"]:0;?></td>
</tr>
<?php }?>
</tbody>
</table>